<!DOCTYPE html>
<html lang="zh">
<head>
<title>雅菡珠宝</title>
<link href="{{url_for('static', filename='css/bootstrap.min.css')}}" rel="stylesheet" type="text/css" />
<link rel="icon" type="image/ico" href="{{url_for('static', filename='favicon.ico')}}"/> 
<style type="text/css">
      body {
        padding-top: 40px;
        padding-bottom: 40px;
        background-color: #f5f5f5;
      }

      .form-signin {
        max-width: 400px;
        padding: 19px 29px 29px;
        margin: 0 auto 20px;
        background-color: #fff;
        border: 1px solid #e5e5e5;
        -webkit-border-radius: 5px;
           -moz-border-radius: 5px;
                border-radius: 5px;
        -webkit-box-shadow: 0 1px 2px rgba(0,0,0,.05);
           -moz-box-shadow: 0 1px 2px rgba(0,0,0,.05);
                box-shadow: 0 1px 2px rgba(0,0,0,.05);
      }
      .form-signin .form-signin-heading,
      .form-signin .checkbox {
        margin-bottom: 10px;
      }
      .form-signin input[type="text"],
      .form-signin input[type="password"] {
        font-size: 16px;
        height: auto;
        margin-bottom: 15px;
        padding: 7px 9px;
      }

    </style>

<script src="{{url_for('static', filename='js/jquery-1.8.3.min.js')}}" type="text/javascript"></script>
<script src="{{url_for('static', filename='js/bootstrap.min.js')}}" type="text/javascript"></script>
<script language="JavaScript" type="text/javascript">
//<![CDATA[
    $(document).ready(function(){
        $("#name").focus();
    })
//]]>
</script>
</head>

<body>
    <div class="container">
      <form class="form-signin" action="{{url_for('bpAuth.login')}}" method="post">
        <h2 class="form-signin-heading">请登录</h2>
            
        {% with messages = get_flashed_messages(category_filter=["ERROR"]) %}
            {% if messages %}
                <div class="alert">
                  <button type="button" class="close" data-dismiss="alert">&times;</button>
                  <ul>
                    {% for message in messages %}
                        <li>{{message}}</li>
                    {% endfor %}
                  </ul>
                </div>
            {% endif %}
        {% endwith %}
        
        <input type="text" class="input-block-level" placeholder="用户名" name="name" id="name">
        <input type="password" class="input-block-level" placeholder="密码" name="password" id="password">
        <input type="text" class="input-block-level col-md-3" placeholder="验证码" name="captcha" id="captcha"><img title='看不清？点击刷新图片' id='cap' src="/auth/get_captcha" onclick='changeCap()'/>
        <p class=""><button class="btn btn-large btn-primary" type="submit">登入</button></p>
      </form>

    </div> <!-- /container -->
</body>
</html>